package com.njust.controller.BeanNameUrlHander;

import org.springframework.stereotype.Controller;
import org.springframework.web.servlet.ModelAndView;
import org.springframework.web.servlet.mvc.AbstractController;


import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;

/**
 * 该Controller使用BeanNameUrlHandlerMapping进行Url进行映射
 * 注意点：
 */
@Controller("/beanNameTest")
public class BeanNameUrlController extends AbstractController {


    @Override
    protected ModelAndView handleRequestInternal(HttpServletRequest request, HttpServletResponse response) throws Exception {
        ModelAndView mv = new ModelAndView("success.jsp");
        mv.addObject("message", "默认的映射处理器");
        return mv;
    }






}
